<?php

class m110713_105908_loan_columns extends CDbMigration
{
	public function safeUp()
	{
		$this->addColumn('dycrm_loan', 'securityAddress2', 'string');
		$this->addColumn('dycrm_loan', 'securitySuburb2', 'string');
		$this->addColumn('dycrm_loan', 'securityPostcode2', 'string');
		$this->addColumn('dycrm_loan', 'securityState2', 'string');
		$this->addColumn('dycrm_loan', 'securityCountry2', 'string');
		
		$this->addColumn('dycrm_loan', 'securityAddress3', 'string');
		$this->addColumn('dycrm_loan', 'securitySuburb3', 'string');
		$this->addColumn('dycrm_loan', 'securityPostcode3', 'string');
		$this->addColumn('dycrm_loan', 'securityState3', 'string');
		$this->addColumn('dycrm_loan', 'securityCountry3', 'string');
		
		
		
		$this->addColumn('dycrm_loan', 'loanAccountBSB', 'string');
		$this->addColumn('dycrm_loan', 'loanAccountNo', 'string');
		$this->addColumn('dycrm_loan', 'savingAccountBSB', 'string');
		$this->addColumn('dycrm_loan', 'savingAccountNo', 'string');
	}

	public function safeDown()
	{
		$this->dropColumn('dycrm_loan', 'securityAddress2');
		$this->dropColumn('dycrm_loan', 'securitySuburb2');
		$this->dropColumn('dycrm_loan', 'securityPostcode2');
		$this->dropColumn('dycrm_loan', 'securityState2');
		$this->dropColumn('dycrm_loan', 'securityCountry2');
		
		$this->dropColumn('dycrm_loan', 'securityAddress3');
		$this->dropColumn('dycrm_loan', 'securitySuburb3');
		$this->dropColumn('dycrm_loan', 'securityPostcode3');
		$this->dropColumn('dycrm_loan', 'securityState3');
		$this->dropColumn('dycrm_loan', 'securityCountry3');
		
		$this->dropColumn('dycrm_loan', 'loanAccountBSB');		
		$this->dropColumn('dycrm_loan', 'loanAccountNo');
		$this->dropColumn('dycrm_loan', 'savingAccountBSB');
		$this->dropColumn('dycrm_loan', 'savingAccountNo');
	}
}